package game.resource;

import engine.filesystem.Resource_A;
import engine.video.blit.SpriteInfo;

public class SpriteResource extends Resource_A {
	public SpriteResource(String name, SpriteInfo spriteInfo) {
		super(name);
		_SpriteInfo = spriteInfo;
	}
	
	private SpriteInfo _SpriteInfo;
	
	private int _RefCount;
	
	@Override
	public boolean isValid() {
		return (_SpriteInfo != null);
	}

	@Override
	protected void aquire() {
		_RefCount++;
	}

	@Override
	protected void release() {
		_RefCount--;
	}
	
	public SpriteInfo getSprite() {
		return _SpriteInfo;
	}
}